<?php
/**
* @version		$Id: helper.php 2007-10-17 vinaora $
* @package		Joomla
* @copyright		Copyright (C) 2006 - 2008 khanghk@gmail.com. All rights reserved.
* @license		GNU/GPL, see LICENSE.php
* Joomla! is free software. This version may have been modified pursuant
* to the GNU General Public License, and as distributed it includes or
* is derivative of works licensed under the GNU General Public License or
* other free or open source software licenses.
* See COPYRIGHT.php for copyright notices and details.
*/

//neu ko dc phem thi ko cho truy cap
defined('_JEXEC') or die('Restricted access');

class modYM
{
	function hello(&$params)
	{
		//nay data ra
		$nick	=	@$params->get('nickname', 'yahoo');
		$comm	=	@$params->get('posttext', '');
		
		//cat mang de lay ra toan bo cac nick
		$arr= explode(',',$nick);

		$content 	= '<div><center>';
		
		for( $i = 0; $i < count($arr) ; $i++ )
		{	
			$content 	.='<a href="ymsgr:sendim?'.$arr[$i].'"><img border="0" src="http://opi.yahoo.com/online?u='.$arr[$i].'&amp;m=g&amp;t=2%3C/a%3E" alt="'.$arr[$i].'" /></a><br>';
		}
		
		$content 	.= $comm.'</center></div>';
		echo $content;
	}
}
?>